package com.ailanyin.modules.im.security;

import com.ailanyin.common.base.exception.Assert;
import com.ailanyin.common.security.utils.TokenUtil;

/**
 * @author ailanyin
 * @version 1.0
 * @since 2022/11/30 0030 上午 11:38
 */
public class WebsocketSecurity {

    public void checkSecurity(String token) {
        if (!TokenUtil.validateToken(token)) {
            Assert.fail("Websocket 鉴权失败, 请重新登录!");
        }
    }
}
